<?php
namespace App\Model\CustomGame;

use App\Model\BaseModel;
use Illuminate\Support\Facades\DB;

/**
 * 自定义游戏模型
 */
class CustomGame extends BaseModel
{

    /**
     * 是否展示，是
     */
    const IS_SHOW_TRUE = 1;

    /**
     * 是否展示，否
     */
    const IS_SHOW_FALSE = 0;

    protected $table = 'custom_game';

    public function saveCustomGame ($data) {
        return curl_request(getKkaudioApiUrl() . '/inner/customGame/saveCustomGame', $data, 'json', 'POST');
    }

    public function getGameListByPage ($data) {
        return curl_request(getKkaudioApiUrl() . '/inner/customGame/getGameList', $data, 'urlencoded', 'GET');
    }

    public function getOneGame ($data) {
        return curl_request(getKkaudioApiUrl() . '/inner/customGame/getOneGame', $data, 'urlencoded', 'GET');
    }
}
